Back to course home
0% completed
Vote For New Content
Python Variables and Operators
Python - Variables
Python - Data types
Python - Numbers
Python - Booleans
Python - Type Conversions
Python - Operators
Quiz
Python Conditionals
Introduction to Conditional Statements in Python
Python - If...Else
Python - Match Case
Quiz
Python loops
Introduction to loops in Python
Python - for loop
Python - while loop
Python - Loop Control
Python - for else and while else loop
Quiz
Python Strings
Introduction to Strings in Python
Python - String Operators
Python Slicing Strings
Python - String Methods
Quiz
Python Array
Introduction to Array in Python
Python - Array Methods
Quiz
Python Lists
Introduction to Lists in Python
Python - Add and Remove List Items
Python - List Comprehension
Python - List Methods
Quiz
Python Tuples
Introduction to Tuple in Python
Python - Unpack Tuple Items
Python - Join Tuples
Python - Tuple Methods
Quiz
Python -Dictionaries
Introduction to Dictionary in Python
Python - Nested Dictionaries
Python - Dictionary Methods
Quiz
Python -Sets
Introduction to set in Python
Python - set Operations
Python - Set Methods
Quiz
Python Functions and Modules
Introductions to Function in Python
Python - Function Arguments
Recursive Functions
Python - Variable scope
Importing Modules
Quiz
Your First Python Program
Welcome to your first step in Python programming! In this lesson, you'll write a simple program that displays the message "Hello, World!" on your screen. This traditional first program is an excellent way for beginners to test their setup and get comfortable with basic Python syntax.
Example
Python3
. . . .
Explanation:
- The
print()function is used in Python to output information to the console. Here, it is used to print the string"Hello, World!".print("Hello, World!")— This command tells Python to display the text inside the quotation marks.
What You've Learned
- Basic Syntax: You've used the
print()function, which is a fundamental aspect of Python for displaying output. - String Handling: The text "Hello, World!" is a string, a type of data in Python that is used for representing text.
Congratulations on running your first Python program! This simple exercise introduces you to writing and executing Python code, setting the foundation for more complex programming tasks ahead.
Python Application Areas
Python - Basic Syntax
Mark as Completed
On this page
Example
What You've Learned